<?php

namespace Database\Seeders;

use App\Models\Address;
use Illuminate\Database\Seeder;

class AddressSeeder extends Seeder
{
  /**
   * Run the database seeds.
   */
  public function run()
  {
    // Francisco Ramones (c/o Duomo)
    // Via Carlo Maria Martini, 1
    // 20122 Milano (MI)
    $firstAddress = new Address();
    $firstAddress->user_id = 1;
    $firstAddress->district_id = 53;
    $firstAddress->city_id = 2322;
    $firstAddress->zipcode_id = 2322;
    $firstAddress->type_id = 1;
    $firstAddress->address = 'Via Carlo Maria Martini';
    $firstAddress->house_number = '1';
    $firstAddress->save();

    // Barry Allen (c/o Uffizi)
    // Piazzale degli Uffizi, 6
    // 50122 Firenze (FI)
    $secondAddress = new Address();
    $secondAddress->user_id = 2;
    $secondAddress->district_id = 35;
    $secondAddress->city_id = 2768;
    $secondAddress->zipcode_id = 5319;
    $secondAddress->type_id = 2;
    $secondAddress->address = 'Piazzale degli Uffizi';
    $secondAddress->house_number = '6';
    $secondAddress->save();

    // Citizien (c/o Colosseo)
    // Piazza del Colosseo, 1
    // 00184 Roma (RM)
    $thirdAddress = new Address();
    $thirdAddress->user_id = 3;
    $thirdAddress->district_id = 80;
    $thirdAddress->city_id = 5814;
    $thirdAddress->zipcode_id = 121;
    $thirdAddress->type_id = 3;
    $thirdAddress->address = 'Piazza del Colosseo, 1';
    $thirdAddress->house_number = '1';
    $thirdAddress->save();
  }
}
